<?php

class Address_Form_Address extends Zend_Form
{

    public function init()
    {
        $this->setAttrib('id', 'addressForm');
	
	$address_id = new Zend_Dojo_Form_Element_TextBox('address_id');
	
	$name1 = new Zend_Dojo_Form_Element_TextBox('name1');
	$name1->setLabel('name1');
	$name1->setRequired(true);
	
	$name2 = new Zend_Dojo_Form_Element_TextBox('name2');
	$name2->setLabel('name2');
	
	$street = new Zend_Dojo_Form_Element_TextBox('street');
	$street->setLabel('street');
	
	$zipcode = new Zend_Dojo_Form_Element_TextBox('zipcode');
	$zipcode->setLabel('zipcode');
	
	$city = new Zend_Dojo_Form_Element_TextBox('city');
	$city->setLabel('city');
	
	$address_submit = new Zend_Dojo_Form_Element_Button('address_submit');
	$address_submit->setLabel('speichern');
	$address_submit->setDijitParam('onClick', 'saveAddressData');
	
	$this->addElements(array(
	    $address_id,
	    $name1,
	    $name2,
	    $street,
	    $zipcode,
	    $city,
	    $address_submit
	));
    }


}

